                 Marathon Sound Converter
                                                         by James Knight
This program allows you to convert Marathon 2 Sound files to resource sound files (ie:normal sounds that can be edited and changed with any sound program) and back again.  This allows you to use your favorite sound editing program on the existing sounds or record new ones, and then use them with Marathon.  It will convert files with type 'snd2' (Marathon 2 format) into normal sounds, and files with type 'rsrc' (resource format) into Marathon 2 sounds.

The newest version, as well as any notes, etc. can be found at "http://www.ai.mit.edu/people/jknight/M2sndconv.html"

This program has two major modes:
1) Marathon 2 -> Resource
	In this mode all the sounds from the Marathon 2 file are converted to resources.  A resource ('shdr') is also made which tells the program how to convert back to Marathon 2 format
2) Resource -> Marathon 2
	This mode converts the sounds described by the 'shdr' resource back to Marathon 2 format.  Only sounds with the correct sound IDs (the ones that were made in the original conversion) are converted.  This is all right, since Marathon wouldn't use extra sounds if I did convert them.  You can, however have up to eight variations for the sounds, even if there was only one to begin with.

=================================================================================
Resource ID description:
Format=SxxxV
S=sound set.  1 means 8-bit set, 2 means 16-bit set.
x=sound ID.  Only recognized sound ID's will be converted.
V=variation.  variations can be from 0-7, but if there is a sound Sxxx7, there must be sounds Sxxx6, Sxxx5, ..., Sxxx0
Exception: number 4545 is not the fifth variation of sound 454.  It is seperate.  (Grrr.)  This means that sound 454 can only have 4 variations (up to 3) or else bad things happen.

ex: 10643 = 8-bit set, sound number 064, variation 3.
ex: 24430 = 16-bit set, sound number 443, variation 0.
=================================================================================

Right now, modems aren't too fast, and downloading a 15meg file, let alone a 5meg one is not something most users want to do.  So, here are some hints for making your sound file smaller:
	Don't provide 16-bit sounds.  Delete them all.  Your sound file is approx. 3 times as large if there are 16-bit sounds in it.  If there are no 16-bit sounds in a file, the user must switch to 8-bit mode, or (s)he will get no sound at all.  <This will be changed in a future version>
	Delete unnecessary variations.
	Compress some of the sounds.  Note that this will decrease performance on slower computers so only compress seldom used sounds.  I have not tested this, so please tell me whether it works or not.
	Use smaller sampling rates.  This will reduce the sound quality, but will take less disk space.  It's a trade-off.
	Don't use ambient sounds
	Only change some of the sounds and let the user combine your sound file with Bungie's.  This is a complicated thing for the user to do at this point (it requires resedit).  It will be made easier.

Version History
Changes for version 0.5:
	Changed compliers to Metroworks Codewarrior 7 C++ from Symantec C++ v.7.  As a result, the app is now fat, for whatever difference that makes.
	Improved documentation
	Works correctly if some sound ID's are missing, so now you can delete things such as ambient sounds, etc. without fear that Marathon will crash.
	I now have Marathon 2, so making this program should be much easier!

Changes for version 0.4:
	Fixed Marathon 2 Release conversion.  Now puts the first sound set of sounds (8-bit) in resources starting with 10000, and the second set (16-bit) in resources starting with 20000.

Changes for version 0.3:
	Added half useful error messages
	Fixed two very dumb bugs that prevented converting back to Marathon 2 format
	Added support for Marathon 2 Release version
	Note: This version does not support the 16-bit sounds in the Marathon 2 release sound file.  It just ignores them.  Thats why the files it makes are about a third of the size of the original.

Changes for version 0.2:
	Added ability to convert files back to Marathon 2 format.
	Added Progress Bar and ability to stop the conversion.
	Added Application Icon by Neal Bailey.
	Fixed some dumb bugs.

Future Plans:
	An installer program that you can put your sounds into, and it will copy them onto a Marathon2 sound file.
	Names for the resources, so you know which numbers are what sounds
	Remap 16-bit sounds that are not provided onto 8-bit sounds that are.
	Put up a menu bar.

NOTE: I would suggest not distributing sound files with some of the original sounds in them, because of copyright problems, and large download problems.  For now, the best way to distribute partial sound sets is probably in resource form, with instructions for using this program and resedit to combine the originals and your new ones.  If you're patient, you could wait until I finish my installer app.

If you want to suggest things, make any comments, or report bugs, email me at the address below.  If you make a sound file for Marathon 2 with this program, I'd appreciate it if you sent me email saying where you uploaded it, and that you really like my program.

  I have included a Resourcer template describing the M2 sound file data fork for those curious people.  It describes the 'shdr' resource this program makes in files converted to resource format (as well as the beginning of Marathon 2's Sound File).  Unfortuanately, Resourcer can't handle the truth... wait, I mean the new (release) format without a filter, and I don't feel like making one.  If you want to make it work, you just need to multiply the number at offset $A by two and then open it with the template.  The first half are the 8-bit sounds, and the second half are the 16-bit sounds.  Don't forget to change it back before you save it.


Thanks section:
Thanks to the following people for helping me in some way:
W. Neal Bailey, III for the icon
Matt Segur for the list of names of the sounds
Chris Kanter for getting me doing Marathon 2 Release support correctly ;)


Thanks also to the following people who nicely sent in bug reports and tested new releases so I could fix mistakes and add features:
W. Neal Bailey, III
Robert E. Klein
Nick Zeitlin
Matt Segur
Mike Gaines


James Knight
jknight@ai.mit.edu

Marathon Sound Converter is 1995 by James Knight
When you redistribute this program, these docs must be with it.  This is a beta version.  If it destroys your hard disk, deletes your very important work, etc. don't complain to me.  I warned you.  It didn't do any of that to me or anyone who has tried it (that I know of), but this program has not been thoroughly tested.  This is a beta version.  Use at your own risk.